package beanstao.util.type.base;

import beanstao.util.exception.technical.util.reflect.FailToCastObjectException;
import beanstao.util.type.Castor;

@SuppressWarnings({ "unchecked", "rawtypes" })
public class String2Enum extends Castor<String, Enum>
{

	@Override
	public Enum cast(String src, Class<?> toType, String... args) throws FailToCastObjectException
	{
		return Enum.valueOf((Class<Enum>) toType, src);
	}

}
